import request from "../utils/request";

// 用户管理接口----------------------------------

// 获取用户管理列表
export const fetchUserlistData = (params) => {
  return request({
    url: "/web/user/getList",
    method: "get",
    params: params,
  });
};

// 创建/修改用户管理
export const fetchUsertCreate = (data) => {
  return request({
    url: "/web/user/create",
    method: "post",
    data: data,
  });
};

// 删除用户管理
export const fetchDeleteUser = (data) => {
  return request({
    url: "/web/user/deleteById",
    method: "post",
    data: data,
  });
};

// 获取用户下载列表
export const fetchUserDownloadList = (params) => {
  return request({
    url: "/web/userDownload/getList",
    method: "get",
    params: params,
  });
};

// 修改订单有效期,给用户加会员时间
export const fetchModifyOrderDuration = (params) => {
  return request({
    url: "/web/userOrder/modifyOrderDuration",
    method: "get",
    params: params,
  });
};
